ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
↳ QTRS
↳ Overlay + Local Confluence
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
AP(ap(map, f), xs) → AP(ap(if, ap(isEmpty, xs)), f)
AP(ap(ap(if, false), f), xs) → AP(last, xs)
AP(ap(ap(if, false), f), xs) → AP(f, ap(last, xs))
AP(ap(map, f), xs) → AP(if, ap(isEmpty, xs))
AP(ap(ap(if, false), f), xs) → AP(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
AP(ap(map, f), xs) → AP(isEmpty, xs)
AP(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(last, ap(ap(cons, y), ys))
AP(ap(ap(if, false), f), xs) → AP(ap(map, f), ap(dropLast, xs))
AP(ap(map, f), xs) → AP(ap(ap(if, ap(isEmpty, xs)), f), xs)
AP(ap(ap(if, false), f), xs) → AP(map, f)
AP(ap(ap(if, false), f), xs) → AP(cons, ap(f, ap(last, xs)))
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(dropLast, ap(ap(cons, y), ys))
AP(ap(ap(if, false), f), xs) → AP(dropLast, xs)
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
AP(ap(map, f), xs) → AP(ap(if, ap(isEmpty, xs)), f)
AP(ap(ap(if, false), f), xs) → AP(last, xs)
AP(ap(ap(if, false), f), xs) → AP(f, ap(last, xs))
AP(ap(map, f), xs) → AP(if, ap(isEmpty, xs))
AP(ap(ap(if, false), f), xs) → AP(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
AP(ap(map, f), xs) → AP(isEmpty, xs)
AP(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(last, ap(ap(cons, y), ys))
AP(ap(ap(if, false), f), xs) → AP(ap(map, f), ap(dropLast, xs))
AP(ap(map, f), xs) → AP(ap(ap(if, ap(isEmpty, xs)), f), xs)
AP(ap(ap(if, false), f), xs) → AP(map, f)
AP(ap(ap(if, false), f), xs) → AP(cons, ap(f, ap(last, xs)))
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(dropLast, ap(ap(cons, y), ys))
AP(ap(ap(if, false), f), xs) → AP(dropLast, xs)
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
AP(ap(ap(if, false), f), xs) → AP(last, xs)
AP(ap(map, f), xs) → AP(ap(if, ap(isEmpty, xs)), f)
AP(ap(ap(if, false), f), xs) → AP(f, ap(last, xs))
AP(ap(ap(if, false), f), xs) → AP(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
AP(ap(map, f), xs) → AP(if, ap(isEmpty, xs))
AP(ap(map, f), xs) → AP(isEmpty, xs)
AP(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(last, ap(ap(cons, y), ys))
AP(ap(ap(if, false), f), xs) → AP(ap(map, f), ap(dropLast, xs))
AP(ap(map, f), xs) → AP(ap(ap(if, ap(isEmpty, xs)), f), xs)
AP(ap(ap(if, false), f), xs) → AP(map, f)
AP(ap(ap(if, false), f), xs) → AP(cons, ap(f, ap(last, xs)))
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(dropLast, ap(ap(cons, y), ys))
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
AP(ap(ap(if, false), f), xs) → AP(dropLast, xs)
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
↳ AND
↳ QDP
↳ QDPOrderProof
↳ QDP
↳ QDP
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(dropLast, ap(ap(cons, y), ys))
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
DROPLAST(cons(x, cons(y, ys))) → DROPLAST(cons(y, ys))
map(x0, x1)
if(true, x0, x1)
if(false, x0, x1)
isEmpty(nil)
isEmpty(cons(x0, x1))
last(cons(x0, nil))
last(cons(x0, cons(x1, x2)))
dropLast(nil)
dropLast(cons(x0, nil))
dropLast(cons(x0, cons(x1, x2)))
The following pairs can be oriented strictly and are deleted.
The remaining pairs can at least be oriented weakly.
AP(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(dropLast, ap(ap(cons, y), ys))
[DROPLAST1, cons1]
DROPLAST1: [1]
cons1: [1]
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
↳ AND
↳ QDP
↳ QDPOrderProof
↳ QDP
↳ PisEmptyProof
↳ QDP
↳ QDP
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
↳ AND
↳ QDP
↳ QDP
↳ QDPOrderProof
↳ QDP
AP(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(last, ap(ap(cons, y), ys))
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
LAST(cons(x, cons(y, ys))) → LAST(cons(y, ys))
map(x0, x1)
if(true, x0, x1)
if(false, x0, x1)
isEmpty(nil)
isEmpty(cons(x0, x1))
last(cons(x0, nil))
last(cons(x0, cons(x1, x2)))
dropLast(nil)
dropLast(cons(x0, nil))
dropLast(cons(x0, cons(x1, x2)))
The following pairs can be oriented strictly and are deleted.
The remaining pairs can at least be oriented weakly.
AP(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → AP(last, ap(ap(cons, y), ys))
[LAST1, cons1]
LAST1: [1]
cons1: [1]
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
↳ AND
↳ QDP
↳ QDP
↳ QDPOrderProof
↳ QDP
↳ PisEmptyProof
↳ QDP
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
↳ AND
↳ QDP
↳ QDP
↳ QDP
↳ QDPOrderProof
AP(ap(ap(if, false), f), xs) → AP(f, ap(last, xs))
AP(ap(ap(if, false), f), xs) → AP(ap(map, f), ap(dropLast, xs))
AP(ap(map, f), xs) → AP(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
The following pairs can be oriented strictly and are deleted.
The remaining pairs can at least be oriented weakly.
AP(ap(ap(if, false), f), xs) → AP(f, ap(last, xs))
Used ordering: Combined order from the following AFS and order.
AP(ap(ap(if, false), f), xs) → AP(ap(map, f), ap(dropLast, xs))
AP(ap(map, f), xs) → AP(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap1 > if > [false, map]
ap1 > last > cons > [dropLast, nil] > [false, map]
ap1 > isEmpty > [false, map]
ap1 > true > [false, map]
dropLast: multiset
true: multiset
last: multiset
if: multiset
false: multiset
map: multiset
nil: multiset
ap1: [1]
isEmpty: multiset
cons: multiset
↳ QTRS
↳ Overlay + Local Confluence
↳ QTRS
↳ DependencyPairsProof
↳ QDP
↳ EdgeDeletionProof
↳ QDP
↳ DependencyGraphProof
↳ AND
↳ QDP
↳ QDP
↳ QDP
↳ QDPOrderProof
↳ QDP
AP(ap(ap(if, false), f), xs) → AP(ap(map, f), ap(dropLast, xs))
AP(ap(map, f), xs) → AP(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(map, f), xs) → ap(ap(ap(if, ap(isEmpty, xs)), f), xs)
ap(ap(ap(if, true), f), xs) → nil
ap(ap(ap(if, false), f), xs) → ap(ap(cons, ap(f, ap(last, xs))), ap(ap(map, f), ap(dropLast, xs)))
ap(isEmpty, nil) → true
ap(isEmpty, ap(ap(cons, x), xs)) → false
ap(last, ap(ap(cons, x), nil)) → x
ap(last, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(last, ap(ap(cons, y), ys))
ap(dropLast, nil) → nil
ap(dropLast, ap(ap(cons, x), nil)) → nil
ap(dropLast, ap(ap(cons, x), ap(ap(cons, y), ys))) → ap(ap(cons, x), ap(dropLast, ap(ap(cons, y), ys)))
ap(ap(map, x0), x1)
ap(ap(ap(if, true), x0), x1)
ap(ap(ap(if, false), x0), x1)
ap(isEmpty, nil)
ap(isEmpty, ap(ap(cons, x0), x1))
ap(last, ap(ap(cons, x0), nil))
ap(last, ap(ap(cons, x0), ap(ap(cons, x1), x2)))
ap(dropLast, nil)
ap(dropLast, ap(ap(cons, x0), nil))
ap(dropLast, ap(ap(cons, x0), ap(ap(cons, x1), x2)))